From 906d187f0fbbebc11638ca0209ad247efc2ef399 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Florian=20M=C3=BCllner?= Date: Fri, 24 Oct 2025 13:39:03 +0200 Subject: [PATCH] lint: Enable 'prefer-const' rule Now that all code conforms with the rule, we can enforce it to make sure we stick to it with new code. Relax the rule for destructuring, so we don't have to jump through hoops to avoid "mixed" assignments. Part-of: --- tools/eslint.config.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/eslint.config.js b/tools/eslint.config.js index 6c7c37742..8c59c581e 100644 --- a/tools/eslint.config.js +++ b/tools/eslint.config.js @@ -32,6 +32,9 @@ export default defineConfig([ afterColon: true, }], 'prefer-arrow-callback': 'error', + 'prefer-const': ['error', { + destructuring: 'all', + }], 'jsdoc/require-param-description': 'off', 'jsdoc/require-jsdoc': ['error', { exemptEmptyFunctions: true, -- 2.39.5